package com.tenbent.product.base.enums.error;

import com.tenbent.product.base.enums.base.BaseEnum;

/**
 * 异常枚举
 *
 * @author Randy
 *
 *         Created by ThinkPad on 2017/8/4.
 */
public enum ErrorEnum implements BaseEnum {

	DATA("数据层异常", 10001), SERVICE("服务层异常", 20001), CONTROLLER("服务层异常", 30001);

	private String name;

	private Integer code;

	ErrorEnum(String name, Integer code) {
		this.name = name;
		this.code = code;
	}

	@Override
	public int getValue() {
		return code;
	}

	@Override
	public String getName() {
		return name;
	}
}
